Conversation
… with audit logging, clarify agent deployment, and adjust firmware memory limits.
…tion - Increase GOMEMLIMIT from 8MiB to 24MiB in init script overlay (8MiB caused Go GC to spin at 100% CPU on the 57MB RAM board) - Add comprehensive [AUDIT] logging to executeHeartbeat for tracing every step of heartbeat filter decisions - Make heartbeat log() use stderr fallback instead of silently swallowing file I/O errors - Add truncateForLog helper for safe log output
Add rule 4 to system prompt: when presenting research or web search results, always include relevant URLs so users can follow up directly.
…entation for agent performance settings and future optimization plans.
…es, fix init script logging and heartbeat TrimSpace - Delete doc/picoclaw_community_roadmap_260216.md (stale PicoClaw content) - Add doc/ROADMAP.md (versioned v0.2.0 through future) - Add doc/BACKUP_RESTORE.md (scp backup/restore workflow) - Add CONTRIBUTING.md (PR process, AI disclosure) - Rewrite doc/FLASHING_GUIDE.md (full SOCToolKit flow) - Add picoclaw-latest/ to .gitignore - Add lessons #11, #12 to AGENTS.md (upstream ref, log paths) - Fix init script: sh -c wrapper for proper logging with start-stop-daemon -b - Fix heartbeat buildPrompt: use strings.TrimSpace so empty HEARTBEAT.md is treated as empty
Part A - Cron improvements: - Add MaxRuns/RunCount fields to CronJob for bounded recurrence - Auto-delete jobs when MaxRuns reached in executeJobByID - Add max_runs parameter to cron tool schema - Improve at_seconds, every_seconds, message descriptions - Show run progress [run N/M] in listJobs output Part B - Context window & session fixes: - Increase MaxTokens default: 8192 -> 16384 - Increase MaxToolIterations: 15 -> 25 - Remove user-facing memory threshold notification (log only) - Fix hardcoded max_tokens=8192 in LLM calls to use config value - Port upstream forceCompression fix (append to system prompt) Boot fix: - Add NTP clock wait guard to S99luckyclaw init script - Prevents Discord TLS failure on cold boot (no battery RTC) - Waits up to 30s for system clock to sync before starting Docs: - Update AGENTS.md with new defaults - Add session management items to IMPROVEMENTS.md
README: - Fix Go badge: 1.22+ → 1.25+ - Fix messaging step wording (Telegram and/or Discord) - Update channel table: WhatsApp WIP, Slack inherited/untested - Fix binary path: usr/local/bin → usr/bin - Fix GOMEMLIMIT: 8MiB → 24MiB (two locations) Flashing Guide: - Rewrite to match annotated screenshots - Add RV1103/RV1106 board variant note with releases links - Add Windows Security trust step, chip selection dialog - Bundle all downloads from releases page - Add 8 step-by-step screenshots to assets/flashing/ Onboarding: - Make Telegram and Discord setup optional (y/n prompts) - Add Discord onboarding flow (token + allow_from) Other: - Update config.example.json defaults (16384 tokens, 25 iterations) - Fix picoclaw upstream bug reference (openclaw → picoclaw) - Add OTA binary update improvement to IMPROVEMENTS.md - Confirm infinite optimization loop bug still in picoclaw-latest
…e naming - Add Discord badge in README header - Add supported boards table (Pico Plus/RV1103, Pro Max/RV1106) - Add IMPORTANT note: only these two boards are supported - Add Community section with Discord link - Update image naming: luckyclaw-luckfox_pico_plus_rv1103-vX.X.X.img - Update overlay config defaults (model, max_tokens, max_tool_iterations) - Sync overlay config to SDK
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d18d4acc3e
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
pkg/config/config.go
Outdated
| suffix := filepath.Base(ws) | ||
| return filepath.Join(c.configDir, suffix) |
There was a problem hiding this comment.
Preserve full ~/ workspace path when rebasing
WorkspacePath() now rewrites ~/... paths using filepath.Base(ws), which drops all intermediate path segments and makes resolution depend on whether configDir was set by LoadConfig. In practice this can redirect configured workspaces (for example ~/.luckyclaw/custom/workspace becomes <configDir>/workspace) and split data across directories when one code path uses DefaultConfig and another uses LoadConfig.
Useful? React with 👍 / 👎.
pkg/heartbeat/service.go
Outdated
| CRITICAL INSTRUCTION: When ALL of the following are true, respond with ONLY the exact text HEARTBEAT_OK — nothing else, no extra information, no status summary: | ||
| 1. System Status is Normal (disk, memory, network all healthy) | ||
| 2. No tasks in HEARTBEAT.md require execution today | ||
| 3. You have NOT executed any tools during this check |
There was a problem hiding this comment.
Reconcile HEARTBEAT_OK criteria with mandatory checks
The heartbeat prompt now allows HEARTBEAT_OK only when no tasks are required and no tools are run, but the default template added in this commit instructs the agent to execute shell checks every cycle. This makes the HEARTBEAT_OK condition effectively unreachable with the shipped template, so normal heartbeats will always require generating a report instead of taking the silent fast path.
Useful? React with 👍 / 👎.
filepath.Base(ws) was stripping all intermediate path segments from the workspace string, so ~/.luckyclaw/custom/workspace would resolve to /oem/.luckyclaw/workspace instead of /oem/.luckyclaw/custom/workspace. Fix: strip only the leading '~' and join the remainder with filepath.Dir(configDir) to preserve the full path structure. Default case (~/.luckyclaw/workspace → /oem/.luckyclaw/workspace) still resolves correctly. Flagged by reviewer bot. All tests pass.
P1 - pkg/config/config.go: WorkspacePath() was using filepath.Base() which dropped all intermediate path segments. ~/.luckyclaw/custom/workspace would silently resolve to /oem/.luckyclaw/workspace, corrupting data. Fixed by stripping only '~' and joining remainder with filepath.Dir(configDir). Default case unaffected. P2 - pkg/heartbeat/service.go: HEARTBEAT_OK condition 3 required 'no tools run', making the silent fast-path unreachable with the default template (which always requires shell checks). Changed to 'all checks returned normal results' to align with the template's own instruction and allow quiet heartbeats.
No description provided.